<template>
  <div>
    <customDialog
      :title="'弹窗标题'"
      :dialogVisible="dialogVisible"
      @close="closeDialog"
      @confirm="confirmDialog"
      top="10vh"
    >
      <div class="dialog_box"></div>
    </customDialog>
  </div>
</template>

<script lang="ts" setup>
import customDialog from "@/components/CustomDialog/index.vue";
import { ref, reactive } from "vue";
import { debounce } from "lodash-es";

const dialogVisible = ref(false);

// 父级电子显示dialog
const showDialog = async () => {
  dialogVisible.value = true;
};

// 确认
const confirmDialog = debounce(() => {}, 300);

// 关闭
const closeDialog = () => {
  dialogVisible.value = false;
};

defineExpose({
  showDialog,
});
</script>

<style scoped lang="scss"></style>
